package ar.com.unlp.fi.lrs.domain;


import javax.persistence.Column;
import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import com.fasterxml.jackson.annotation.JsonTypeName;

/**
 * Espec: https://github.com/adlnet/xAPI-Spec/blob/master/xAPI.md#object
 * 
 *
 */
@Entity
@Table(name = "Activity")
@DiscriminatorValue(value = "ACTIVITY")

@JsonTypeName("ACTIVITY")

public class Activity implements StatementObject{
	
	private long id;
	
	private String name;
	
	private String description;
	
	private String type;

	@Id
	@GeneratedValue
	@Column(name="ID", unique=true, nullable=false)
	public long getId() {
		return id;
	}

	public void setId(long id) {
		this.id = id;
	}

	@Column (name= "NAME", nullable=false)
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Column(name = "DESCRIPTION")
	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

//	@Column(name ="TYPE")
//	public String getType() {
//		return type;
//	}

//	public void setType(String type) {
//		this.type = type;
//	}

	

	@Override
	@Transient
	public String getObjectStatemetnType() {
		return StatementObject.ACTIVITY;
	}
}
